<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"> <style>
	.KEYW {color: #933;}
	.COMM {color: #bbb; font-style: italic;}
	.NUMB {color: #393;}
	.STRN {color: #393;}
	.REGX {color: #339;}
	.linenumber {border-right: 1px dotted #666; color: #666; font-style: normal;}
	</style></head><body><pre><span class='linenumber'>  1</span> <span class="COMM">/*
<span class='linenumber'>  2</span> 12/2007.
<span class='linenumber'>  3</span> The Portal Manager for 2112Portals will keep track and persist settings, the
<span class='linenumber'>  4</span> Portal Admin is applying to Windows (such as width, height, X, Y) or Menus.
<span class='linenumber'>  5</span> It bases on a pluggable architecture that allows all kind of persistency.
<span class='linenumber'>  6</span> Simply implement the required methods (kind of Interface Implementation)
<span class='linenumber'>  7</span>  in a file called portalPersister.js
<span class='linenumber'>  8</span> */</span><span class="WHIT">
<span class='linenumber'>  9</span> 
<span class='linenumber'> 10</span> 
<span class='linenumber'> 11</span> </span><span class="COMM">/*
<span class='linenumber'> 12</span> 2/2008
<span class='linenumber'> 13</span> From now on all global singleton Objects will be held here.
<span class='linenumber'> 14</span> masterControl -> the SnapIn administration.
<span class='linenumber'> 15</span> */</span><span class="WHIT">
<span class='linenumber'> 16</span> 
<span class='linenumber'> 17</span> </span><span class="COMM">/*Dependencies:
<span class='linenumber'> 18</span>    
<span class='linenumber'> 19</span> NS2112   is loaded.
<span class='linenumber'> 20</span> 
<span class='linenumber'> 21</span> */</span><span class="WHIT">
<span class='linenumber'> 22</span> 
<span class='linenumber'> 23</span> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="NAME">includeCSS</span><span class="PUNC">(</span><span class="NAME">theCSSURI</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 24</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 25</span> </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">fileref</span><span class="PUNC">=</span><span class="STRN">""</span><span class="WHIT">
<span class='linenumber'> 26</span> </span><span class="NAME">fileref</span><span class="PUNC">=</span><span class="NAME">document.createElement</span><span class="PUNC">(</span><span class="STRN">"link"</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 27</span> </span><span class="NAME">fileref.setAttribute</span><span class="PUNC">(</span><span class="STRN">"rel"</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">"stylesheet"</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 28</span> </span><span class="NAME">fileref.setAttribute</span><span class="PUNC">(</span><span class="STRN">"type"</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">"text/css"</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 29</span> </span><span class="NAME">fileref.setAttribute</span><span class="PUNC">(</span><span class="STRN">"href"</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">theCSSURI</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 30</span> </span><span class="COMM">//document.getElementsByTagName('head').item(0).appendChild(script);</span><span class="WHIT">
<span class='linenumber'> 31</span> 
<span class='linenumber'> 32</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'> 33</span> 
<span class='linenumber'> 34</span> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="NAME">include</span><span class="PUNC">(</span><span class="NAME">file</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 35</span> </span><span class="WHIT">  </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">script</span><span class="WHIT">  </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">document.createElement</span><span class="PUNC">(</span><span class="STRN">'script'</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 36</span> </span><span class="WHIT">  </span><span class="NAME">script.src</span><span class="WHIT">  </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">file</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 37</span> </span><span class="WHIT">  </span><span class="NAME">script.type</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="STRN">'text/javascript'</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 38</span> </span><span class="WHIT">  </span><span class="NAME">document.getElementsByTagName</span><span class="PUNC">(</span><span class="STRN">'head'</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">item</span><span class="PUNC">(</span><span class="NUMB">0</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">appendChild</span><span class="PUNC">(</span><span class="NAME">script</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 39</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'> 40</span> 
<span class='linenumber'> 41</span> 
<span class='linenumber'> 42</span> 
<span class='linenumber'> 43</span> 
<span class='linenumber'> 44</span> </span><span class="COMM">//Namespace 2112</span><span class="WHIT">
<span class='linenumber'> 45</span> </span><span class="NAME">window.NS2112</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">window.NS2112</span><span class="WHIT"> </span><span class="PUNC">||</span><span class="WHIT"> </span><span class="PUNC">{</span><span class="PUNC">}</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 46</span> 
<span class='linenumber'> 47</span> 
<span class='linenumber'> 48</span> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="NAME">test</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 49</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 50</span> </span><span class="WHIT">   </span><span class="NAME">alert</span><span class="PUNC">(</span><span class="STRN">"TEST"</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 51</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'> 52</span> 
<span class='linenumber'> 53</span> </span><span class="NAME">NS2112.sandboxMode</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 54</span> </span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="STRN">'/2112PowerWindows/'</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 55</span> 
<span class='linenumber'> 56</span> 
<span class='linenumber'> 57</span> 
<span class='linenumber'> 58</span> 
<span class='linenumber'> 59</span> 
<span class='linenumber'> 60</span> </span><span class="COMM">//This is the core portal file that will boot all other modules neccessary to</span><span class="WHIT">
<span class='linenumber'> 61</span> </span><span class="COMM">//get the portal going.</span><span class="WHIT">
<span class='linenumber'> 62</span> </span><span class="COMM">//So that only one file has to be included in an html file.</span><span class="WHIT">
<span class='linenumber'> 63</span> </span><span class="COMM">//NS2112.include("/2112PowerWindows/widgetBase/myFirstWidget/myFirstWidget.js") ;</span><span class="WHIT">
<span class='linenumber'> 64</span> 
<span class='linenumber'> 65</span> 
<span class='linenumber'> 66</span> </span><span class="COMM">//The instance of our global masterController - this is a singleton.</span><span class="WHIT">
<span class='linenumber'> 67</span> 
<span class='linenumber'> 68</span> </span><span class="NAME">NS2112.namespace</span><span class="PUNC">(</span><span class="STRN">'NS2112.portalMan.masterControl'</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 69</span> 
<span class='linenumber'> 70</span> 
<span class='linenumber'> 71</span> </span><span class="NAME">NS2112.m_masterControl</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 72</span> 
<span class='linenumber'> 73</span> </span><span class="NAME">NS2112.portalMan</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 74</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 75</span> </span><span class="WHIT">  </span><span class="WHIT">
<span class='linenumber'> 76</span> </span><span class="WHIT">   </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">m_windowManager</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 77</span> </span><span class="WHIT">  </span><span class="COMM">/*    
<span class='linenumber'> 78</span>    var m_masterControl ;
<span class='linenumber'> 79</span>    this.getMasterControl = function()
<span class='linenumber'> 80</span>    {
<span class='linenumber'> 81</span>       alert('obsolete!') ;
<span class='linenumber'> 82</span>       debugger;
<span class='linenumber'> 83</span>       if( null == m_masterControl )
<span class='linenumber'> 84</span>       {
<span class='linenumber'> 85</span>          m_masterControl = new NS2112.masterControl() ; 
<span class='linenumber'> 86</span>       }
<span class='linenumber'> 87</span>       return m_masterControl ;
<span class='linenumber'> 88</span>    }
<span class='linenumber'> 89</span> 
<span class='linenumber'> 90</span> */</span><span class="WHIT">
<span class='linenumber'> 91</span> </span><span class="WHIT">   </span><span class="NAME">this.getWindowManager</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 92</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 93</span> </span><span class="WHIT">      </span><span class="KEYW">if</span><span class="PUNC">(</span><span class="WHIT"> </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">==</span><span class="WHIT"> </span><span class="NAME">m_windowManager</span><span class="WHIT"> </span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'> 94</span> </span><span class="WHIT">      </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'> 95</span> </span><span class="WHIT">         </span><span class="NAME">m_windowManager</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">new</span><span class="WHIT"> </span><span class="NAME">NS2112.windowManager</span><span class="PUNC">(</span><span class="NUMB">50</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NUMB">50</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NUMB">10</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NUMB">30</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT"> </span><span class="WHIT">
<span class='linenumber'> 96</span> </span><span class="WHIT">      </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'> 97</span> </span><span class="WHIT">      </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">m_windowManager</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'> 98</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'> 99</span> </span><span class="WHIT">   </span><span class="WHIT">
<span class='linenumber'>100</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>101</span> 
<span class='linenumber'>102</span> 
<span class='linenumber'>103</span> </span><span class="NAME">NS2112.portalMan.Versionstring</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="STRN">"1.0. [May.2008]"</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>104</span> 
<span class='linenumber'>105</span> </span><span class="NAME">NS2112.portalMan.SysInfo</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>106</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>107</span> </span><span class="WHIT">   </span><span class="NAME">vInfo</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">YAHOO.env.getVersion</span><span class="PUNC">(</span><span class="STRN">"yahoo"</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>108</span> </span><span class="WHIT">   </span><span class="NAME">strMsg</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="STRN">"2112PowerWindows Version ["</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan.Versionstring</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="STRN">"]\nYUI Version ["</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="NAME">vInfo.version</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">"]\n"</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="WHIT">
<span class='linenumber'>109</span> </span><span class="WHIT">      </span><span class="STRN">"Visit http://2112Portals.com for more details."</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>110</span> </span><span class="WHIT">   </span><span class="NAME">alert</span><span class="PUNC">(</span><span class="NAME">strMsg</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>111</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>112</span> 
<span class='linenumber'>113</span> 
<span class='linenumber'>114</span> </span><span class="NAME">NS2112.portalMan.getMasterControl</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>115</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>116</span> </span><span class="WHIT">   </span><span class="KEYW">if</span><span class="PUNC">(</span><span class="WHIT"> </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">==</span><span class="WHIT"> </span><span class="NAME">NS2112.m_masterControl</span><span class="WHIT"> </span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>117</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>118</span> </span><span class="WHIT">      </span><span class="NAME">NS2112.m_masterControl</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">new</span><span class="WHIT"> </span><span class="NAME">NS2112.masterControl</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT"> </span><span class="WHIT">
<span class='linenumber'>119</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>120</span> </span><span class="WHIT">   </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">NS2112.m_masterControl</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>121</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>122</span> 
<span class='linenumber'>123</span> 
<span class='linenumber'>124</span> 
<span class='linenumber'>125</span> 
<span class='linenumber'>126</span> 
<span class='linenumber'>127</span> </span><span class="NAME">NS2112.portalMan.loadDepends</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>128</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>129</span> </span><span class="WHIT">   </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">silo</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">new</span><span class="WHIT"> </span><span class="NAME">NS2112.snapInLoader</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>130</span> </span><span class="WHIT">      </span><span class="KEYW">try</span><span class="WHIT"> </span><span class="PUNC">{</span><span class="WHIT">         </span><span class="WHIT">
<span class='linenumber'>131</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="WHIT"> </span><span class="NAME">NS2112.portalPath</span><span class="WHIT"> </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'tool-man/core.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>132</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'tool-man/events.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>133</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'tool-man/css.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>134</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'tool-man/coordinates.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>135</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'tool-man/drag.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>136</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'config/portalSettings.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>137</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'runtime12/nlsProvider.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>138</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'runtime12/windowMan.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>139</span> </span><span class="WHIT">   </span><span class="COMM">//The second wave         </span><span class="WHIT">
<span class='linenumber'>140</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'runtime12/snapIn.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">         </span><span class="WHIT">
<span class='linenumber'>141</span> </span><span class="WHIT">         </span><span class="NAME">silo.loadModule2</span><span class="PUNC">(</span><span class="NAME">NS2112.portalPath</span><span class="WHIT">  </span><span class="PUNC">+</span><span class="WHIT"> </span><span class="STRN">'runtime12/coreSnapIn.js'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>142</span> </span><span class="WHIT">      </span><span class="COMM">//loader.loadModules(r_Modules) ;</span><span class="WHIT">
<span class='linenumber'>143</span> </span><span class="WHIT">      </span><span class="PUNC">}</span><span class="WHIT"> </span><span class="KEYW">catch</span><span class="PUNC">(</span><span class="NAME">ex</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>144</span> </span><span class="WHIT">         </span><span class="NAME">alert</span><span class="PUNC">(</span><span class="NAME">ex</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>145</span> </span><span class="WHIT">      </span><span class="PUNC">}</span><span class="WHIT">      </span><span class="WHIT">
<span class='linenumber'>146</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>147</span> 
<span class='linenumber'>148</span> 
<span class='linenumber'>149</span> </span><span class="COMM">//A setting may consist of a top level</span><span class="WHIT">
<span class='linenumber'>150</span> </span><span class="NAME">NS2112.portalMan.getSetting</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="NAME">strTopic</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">strSub</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>151</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>152</span> </span><span class="WHIT">   </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">value</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>153</span> </span><span class="WHIT">   </span><span class="KEYW">try</span><span class="WHIT">
<span class='linenumber'>154</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>155</span> </span><span class="WHIT">      </span><span class="KEYW">if</span><span class="PUNC">(</span><span class="WHIT"> </span><span class="NAME">strSub</span><span class="WHIT"> </span><span class="PUNC">==</span><span class="WHIT"> </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>156</span> </span><span class="WHIT">         </span><span class="NAME">value</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">NS2112.aPortalSettings</span><span class="PUNC">[</span><span class="NAME">strTopic</span><span class="PUNC">]</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>157</span> </span><span class="WHIT">      </span><span class="KEYW">else</span><span class="WHIT">
<span class='linenumber'>158</span> </span><span class="WHIT">         </span><span class="NAME">value</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="NAME">NS2112.aPortalSettings</span><span class="PUNC">[</span><span class="NAME">strTopic</span><span class="PUNC">]</span><span class="PUNC">[</span><span class="NAME">strSub</span><span class="PUNC">]</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>159</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>160</span> </span><span class="WHIT">   </span><span class="KEYW">catch</span><span class="PUNC">(</span><span class="NAME">ex</span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>161</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>162</span> </span><span class="WHIT">      </span><span class="NAME">value</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>163</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>164</span> </span><span class="WHIT">   </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">value</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>165</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>166</span> 
<span class='linenumber'>167</span> 
<span class='linenumber'>168</span> </span><span class="NAME">NS2112.portalMan.getHeaderHeight</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>169</span> </span><span class="WHIT">   </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan.getSetting</span><span class="PUNC">(</span><span class="STRN">'WINDOWS'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">'HEADERHEIGHT'</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>170</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>171</span> 
<span class='linenumber'>172</span> </span><span class="NAME">NS2112.portalMan.getFooterHeight</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>173</span> </span><span class="WHIT">   </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan.getSetting</span><span class="PUNC">(</span><span class="STRN">'WINDOWS'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">'FOOTERHEIGHT'</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>174</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>175</span> 
<span class='linenumber'>176</span> </span><span class="NAME">NS2112.portalMan.getWindowExtX</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>177</span> </span><span class="WHIT">    </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan.getSetting</span><span class="PUNC">(</span><span class="STRN">'WINDOWS'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">'EXTX'</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>178</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>179</span> 
<span class='linenumber'>180</span> </span><span class="NAME">NS2112.portalMan.getWindowExtX</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>181</span> </span><span class="WHIT">    </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan.getSetting</span><span class="PUNC">(</span><span class="STRN">'WINDOWS'</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="STRN">'EXTY'</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>182</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>183</span> 
<span class='linenumber'>184</span> 
<span class='linenumber'>185</span> 
<span class='linenumber'>186</span> </span><span class="COMM">//to be removed - there should no instance of portalMan at all.</span><span class="WHIT">
<span class='linenumber'>187</span> </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">portalMan</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">new</span><span class="WHIT"> </span><span class="NAME">NS2112.portalMan</span><span class="PUNC">(</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>188</span> 
<span class='linenumber'>189</span> 
<span class='linenumber'>190</span> 
<span class='linenumber'>191</span> 
<span class='linenumber'>192</span> 
<span class='linenumber'>193</span> 
<span class='linenumber'>194</span> </span><span class="NAME">getFromDom</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="PUNC">(</span><span class="WHIT"> </span><span class="NAME">domDoc</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">iItemNum</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">strKey</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">strDefault</span><span class="WHIT"> </span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>195</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>196</span> </span><span class="WHIT">    </span><span class="WHIT">
<span class='linenumber'>197</span> </span><span class="WHIT">	</span><span class="KEYW">if</span><span class="PUNC">(</span><span class="WHIT"> </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">!=</span><span class="WHIT"> </span><span class="NAME">domDoc</span><span class="WHIT">  </span><span class="PUNC">&&</span><span class="WHIT">
<span class='linenumber'>198</span> </span><span class="WHIT">	    </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">!=</span><span class="WHIT"> </span><span class="NAME">domDoc.getElementsByTagName</span><span class="PUNC">(</span><span class="NAME">strKey</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">&&</span><span class="WHIT">
<span class='linenumber'>199</span> </span><span class="WHIT">   	 </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">!=</span><span class="WHIT"> </span><span class="NAME">domDoc.getElementsByTagName</span><span class="PUNC">(</span><span class="NAME">strKey</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">item</span><span class="PUNC">(</span><span class="NAME">iItemNum</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">&&</span><span class="WHIT">
<span class='linenumber'>200</span> </span><span class="WHIT">   	 </span><span class="KEYW">null</span><span class="WHIT"> </span><span class="PUNC">!=</span><span class="WHIT"> </span><span class="NAME">domDoc.getElementsByTagName</span><span class="PUNC">(</span><span class="NAME">strKey</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">item</span><span class="PUNC">(</span><span class="NAME">iItemNum</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">firstChild</span><span class="WHIT">
<span class='linenumber'>201</span> </span><span class="WHIT">      </span><span class="PUNC">)</span><span class="WHIT">
<span class='linenumber'>202</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>203</span> </span><span class="WHIT">   	</span><span class="KEYW">return</span><span class="WHIT"> </span><span class="KEYW">new</span><span class="WHIT"> </span><span class="NAME">String</span><span class="PUNC">(</span><span class="NAME">domDoc.getElementsByTagName</span><span class="PUNC">(</span><span class="NAME">strKey</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">item</span><span class="PUNC">(</span><span class="NAME">iItemNum</span><span class="PUNC">)</span><span class="PUNC">.</span><span class="NAME">firstChild.data</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>204</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>205</span> </span><span class="WHIT">   </span><span class="KEYW">else</span><span class="WHIT">
<span class='linenumber'>206</span> </span><span class="WHIT">     </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="NAME">strDefault</span><span class="WHIT"> </span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>207</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>208</span> 
<span class='linenumber'>209</span> </span><span class="COMM">/*funktion zum abschicken eines Formulars mit Enter-Taste*/</span><span class="WHIT">
<span class='linenumber'>210</span> 
<span class='linenumber'>211</span> 
<span class='linenumber'>212</span> </span><span class="KEYW">function</span><span class="WHIT"> </span><span class="NAME">evalKeyForSubmit</span><span class="PUNC">(</span><span class="NAME">event</span><span class="PUNC">,</span><span class="WHIT"> </span><span class="NAME">frm</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="WHIT">
<span class='linenumber'>213</span> </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>214</span> </span><span class="WHIT">    </span><span class="KEYW">var</span><span class="WHIT"> </span><span class="NAME">myEvent</span><span class="WHIT"> </span><span class="PUNC">=</span><span class="WHIT"> </span><span class="PUNC">(</span><span class="NAME">event</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">?</span><span class="WHIT"> </span><span class="NAME">event</span><span class="WHIT"> </span><span class="PUNC">:</span><span class="WHIT"> </span><span class="PUNC">(</span><span class="PUNC">(</span><span class="NAME">window.event</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="PUNC">?</span><span class="WHIT"> </span><span class="NAME">window.event</span><span class="WHIT"> </span><span class="PUNC">:</span><span class="WHIT"> </span><span class="STRN">""</span><span class="PUNC">)</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>215</span> </span><span class="WHIT">    </span><span class="COMM">//alert(myEvent.keyCode);</span><span class="WHIT">
<span class='linenumber'>216</span> 
<span class='linenumber'>217</span> </span><span class="WHIT">   </span><span class="KEYW">if</span><span class="WHIT"> </span><span class="PUNC">(</span><span class="NAME">event</span><span class="WHIT"> </span><span class="PUNC">&&</span><span class="WHIT"> </span><span class="NAME">myEvent.keyCode</span><span class="WHIT"> </span><span class="PUNC">==</span><span class="WHIT"> </span><span class="NUMB">13</span><span class="PUNC">)</span><span class="WHIT"> </span><span class="COMM">// IE: ...event.keyCode...</span><span class="WHIT">
<span class='linenumber'>218</span> </span><span class="WHIT">   </span><span class="PUNC">{</span><span class="WHIT">
<span class='linenumber'>219</span> </span><span class="WHIT">      </span><span class="COMM">// ENTER gedr�ckt, also Formular abschicken      </span><span class="WHIT">
<span class='linenumber'>220</span> </span><span class="WHIT">      </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="KEYW">true</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>221</span> </span><span class="WHIT">   </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>222</span> </span><span class="WHIT">   </span><span class="KEYW">else</span><span class="WHIT">
<span class='linenumber'>223</span> </span><span class="WHIT">      </span><span class="KEYW">return</span><span class="WHIT"> </span><span class="KEYW">false</span><span class="PUNC">;</span><span class="WHIT">
<span class='linenumber'>224</span> 
<span class='linenumber'>225</span> </span><span class="PUNC">}</span><span class="WHIT">
<span class='linenumber'>226</span> 
<span class='linenumber'>227</span> 
<span class='linenumber'>228</span> 
<span class='linenumber'>229</span> 
<span class='linenumber'>230</span> 
<span class='linenumber'>231</span> </span><span class="COMM">/***************************************************************************************************/</span><span class="WHIT">
<span class='linenumber'>232</span> 
<span class='linenumber'>233</span> 
<span class='linenumber'>234</span> 
<span class='linenumber'>235</span> 
<span class='linenumber'>236</span> 
<span class='linenumber'>237</span> 
<span class='linenumber'>238</span> 
<span class='linenumber'>239</span> 
<span class='linenumber'>240</span> </span></pre></body></html>